import http from "@/utils/http";

/** 
* @param 商品信息
*
*/
export const getMemberOrderPre = () => {
    return http({
        url: "/member/order/pre"
    })
}

// 提交订单
export const postMemberOrderPre = (data) => {
    return http({
        url: "/member/order",
        method: 'post',
        data
    })
}

// 获取订单详情
export const getDetailOrderPre = (id) => {
    return http({
        url: `/member/order/${id}`,

    })
}

//模拟支付接口
export const payMock = (data) => {
    return http({
        url: "/pay/mock",
        data
    })
}
// 支付接口
export const payWxpayMinipay = (data) => {
    return http({
        url: "/pay/wxPay/miniPay",
        data
    })
}

// 获取订单列表

export const getMemberOrder = (data) => {
    return http({
        url: "/member/order",
        data
    })
}

// 立即购买

export const getMemberOrderPreNow = (data) => {
    return http({
        url: "/member/order/pre/now",
        data
    })
}